[Unit]
Description=Elasticksearch 8 and Kibana 8
#Requires=network.target

[Service]
Type=simple
User=root
Group=root
Environment=SERVICE=osiselkstack
Environment=COMPOSEFILE=/data/dockers/elkstack/osiselkstack.yml

ExecStart=docker compose -f ${COMPOSEFILE} -p ${SERVICE} up -d
ExecStop=docker compose -f ${COMPOSEFILE} -p ${SERVICE} down
Restart=on-failure
RestartSec=10

[Install]
WantedBy=multi-user.target